/*
 * @Description: 
 * @Author: Sun
 * @Date: 2024-07-10 23:24:45
 * @LastEditors: Sun
 * @LastEditTime: 2024-07-13 10:38:42
 */

import { createApp } from 'vue'
import App from '@/App.vue'
// import './assets/main.css'
//引入模板的全局的样式
import '@/styles/index.scss'
//引入element-plus插件与样式
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
//svg插件需要配置代码
import 'virtual:svg-icons-register'
//引入仓库
import pinia from './store'

// import { createPinia } from 'pinia'
import router from './router'

//引入自定义插件对象:注册整个项目全局组件
import gloalComponent from '@/components'

//配置element-plus国际化
//@ts-expect-error
import zhCn from 'element-plus/dist/locale/zh-cn.mjs'
//暗黑模式需要的样式
import 'element-plus/theme-chalk/dark/css-vars.css'


//获取应用实例对象
const app = createApp(App)
//安装element-plus插件
app.use(ElementPlus, {
  locale: zhCn, //element-plus国际化配置
})



//安装自定义插件
app.use(gloalComponent)
//引入路由鉴权文件
import './permisstion'

//安装仓库
app.use(pinia)
app.use(router)

app.mount('#app')
